package com.zyit.service.impl;

import com.zyit.mapper.ScheduleMapper;
import com.zyit.model.Schedule;
import com.zyit.model.SysUsers;
import com.zyit.model.vo.RegisteredInformation;
import com.zyit.service.ScheduleService;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
public class ScheduleServiceImpl implements ScheduleService {
    @Resource
    private ScheduleMapper scheduleMapper;
    @Override
    public List<Schedule> findByDepartmentAndTime(Schedule schedule) {
        return scheduleMapper.findByDepartmentAndTime(schedule);
    }

    @Override
    public Schedule findByUserIdAndSign(Long userid, Integer sign) {
        return scheduleMapper.findByUserIdAndSign(userid,sign);
    }

    @Override
    public int updateNum(Long id) {
        return scheduleMapper.updateNum(id);
    }

    @Override
    public List<RegisteredInformation> findAll(RegisteredInformation ri) {
        return scheduleMapper.findAll(ri);
    }
}
